package com.hr.mapper;

import com.hr.entity.Book;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

@Mapper
public interface BookMapper {

    void addBook(Book book);

    void deletaBookByBookId(Integer bookId);

    void batchDeleteBook(List<Integer> bookIds);

    void updateBook(Book book);

    List<Book> getBooksByParams(@Param("bookName") String bookName,
                                @Param("categoryId") Integer categoryId,
                                @Param("status") Integer status,
                                @Param("start") Date start,
                                @Param("end") Date end);
}
